<?php

namespace addons\qingdongams\model;

use think\Model;

/**
 * 客户类型 延迟
 */
class CustomerType extends Model
{
    // 表名,不含前缀
    protected $name = 'qingdongams_customer_type';
    // 开启自动写入时间戳字段
    protected $autoWriteTimestamp = 'int';
    // 定义时间戳字段名
    protected $createTime = 'createtime';
    protected $updateTime = 'updatetime';

    public function staff()
    {
        return $this->hasOne(Staff::class, 'id', 'customer_id')->field('id,name,img');
    }


}
